package info.emamian.droplet.core.smsHandler;

import info.emamian.droplet.core.domain.BasicSMS;

public abstract class AbstractSMSHandler {
	private String answer = null;

	protected abstract String processAnswer(BasicSMS sms);

	public abstract String getUsage();

	final public boolean canAnswer(BasicSMS sms) {
		answer = processAnswer(sms);
		if (answer == null)
			return false;
		answer = answer.trim();
		return true;
	}

	final public String getAnswer() {
		return answer;
	}
}
